package jw3.c9.controller;

import jw3.c9.model.Userinfo;
import jw3.c9.utils.QueryByClass;

import java.util.List;

public class Userinfocontroller {
     public  static  boolean login(String Number,String pwd ){
         try{
             QueryByClass<Userinfo>qc=new QueryByClass<>();
             String sql="select * from userinfo where UserNumber=? and pwd=?";
             List<Userinfo>list=qc.select(Userinfo.class,sql,Number,pwd);
             return  list.size()>0;
         }catch (Exception e){
             e.printStackTrace();
         }
         return false;
     }
}
